/**
 * Created by fengliu on 15/8/28.
 */
var path = require('path');
var node_modules = path.resolve(__dirname, 'node_modules');
var deps = [
    // 'react/dist/react.min.js',
    // 'amazeui-react/dist/amazeui.react.min.js',
    // 'amazeui/dist/js/amazeui.min.js',
    // 'jquery/dist/jquery.min.js'
];

var config = {
    entry: ['webpack/hot/dev-server', path.resolve(__dirname, 'app/main.js')],

    output: {
        path: path.resolve(__dirname, 'build'),
        filename: 'bundle.js',
    },
    module: {
        loaders: [
            {
                test: /\.js?$/,
                loader: 'babel'
            }, {
                test: /\.css$/,
                loader: 'style!css'
            }
        ],
        noParse: []
    },
    resolve:{
        alias: {}
    }
};

// deps.forEach(function (dep) {
//     var depPath = path.resolve(node_modules, dep);
//     console.log(depPath);
//     config.resolve.alias[dep.split(path.sep)[0]] = depPath;
//     config.module.noParse.push(depPath);
// });
//console.log(config);
module.exports = config;
